PATHMac OS 8 and 9 Developer Documentation > Human Interface Toolbox > Control Manager >

Programming With the Mac OS 8.5 Control Manager


ControlApplyTextColorRec

If you implement a custom control definition function, when the Control Manager passes the message kControlMsgApplyTextColor in your control definition function's message parameter, it also passes a pointer to a structure of type ControlApplyTextColorRec in the param parameter. The Control Manager sets the ControlApplyTextColorRec structure to contain data describing the current drawing environment, and your control definition function is responsible for using that data to apply the proper text color to the current graphics port.

See Control Definition Message Constants for more details on the kControlMsgApplyTextColor message.

struct ControlApplyTextColorRec
{
    SInt16  depth;
    Boolean colorDevice;
    Boolean active;
};
typedef struct ControlApplyTextColorRec ControlApplyTextColorRec;
typedef ControlApplyTextColorRec* ControlApplyTextColorPtr;

Field descriptions

depth
A signed 16-bit integer. The Control Manager sets this field to specify the bit depth (in pixels) of the current graphics port.
colorDevice
A value of type Boolean . The Control Manager passes a value of true if you are drawing on a color device; otherwise, false .
active
A value of type Boolean . The Control Manager passes a value of true to specify a color suitable for active text; otherwise, false .

© 1999 Apple Computer, Inc. — (Last Updated 20 Jan 99)